Optimal. Leaf size=374 \[ -\frac {c (f x)^{m+1} \left ((m-n+1) (b d-2 a e)-\frac {2 a b e n+4 a c d (m-2 n+1)+b^2 (-d) (m-n+1)}{\sqrt {b^2-4 a c}}\right ) \, _2F_1\left (1,\frac {m+1}{n};\frac {m+n+1}{n};-\frac {2 c x^n}{b-\sqrt {b^2-4 a c}}\right )}{a f (m+1) n \left (b^2-4 a c\right ) \left (b-\sqrt {b^2-4 a c}\right )}-\frac {c (f x)^{m+1} \left (\frac {2 a b e n+4 a c d (m-2 n+1)+b^2 (-d) (m-n+1)}{\sqrt {b^2-4 a c}}+(m-n+1) (b d-2 a e)\right ) \, _2F_1\left (1,\frac {m+1}{n};\frac {m+n+1}{n};-\frac {2 c x^n}{b+\sqrt {b^2-4 a c}}\right )}{a f (m+1) n \left (b^2-4 a c\right ) \left (\sqrt {b^2-4 a c}+b\right )}+\frac {(f x)^{m+1} \left (c x^n (b d-2 a e)-a b e-2 a c d+b^2 d\right )}{a f n \left (b^2-4 a c\right ) \left (a+b x^n+c x^{2 n}\right )} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 1.38, antiderivative size = 374, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 3, integrand size = 29, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.103, Rules used = {1558, 1560, 364} \[ -\frac {c (f x)^{m+1} \left ((m-n+1) (b d-2 a e)-\frac {2 a b e n+4 a c d (m-2 n+1)+b^2 (-d) (m-n+1)}{\sqrt {b^2-4 a c}}\right ) \, _2F_1\left (1,\frac {m+1}{n};\frac {m+n+1}{n};-\frac {2 c x^n}{b-\sqrt {b^2-4 a c}}\right )}{a f (m+1) n \left (b^2-4 a c\right ) \left (b-\sqrt {b^2-4 a c}\right )}-\frac {c (f x)^{m+1} \left (\frac {2 a b e n+4 a c d (m-2 n+1)+b^2 (-d) (m-n+1)}{\sqrt {b^2-4 a c}}+(m-n+1) (b d-2 a e)\right ) \, _2F_1\left (1,\frac {m+1}{n};\frac {m+n+1}{n};-\frac {2 c x^n}{b+\sqrt {b^2-4 a c}}\right )}{a f (m+1) n \left (b^2-4 a c\right ) \left (\sqrt {b^2-4 a c}+b\right )}+\frac {(f x)^{m+1} \left (c x^n (b d-2 a e)-a b e-2 a c d+b^2 d\right )}{a f n \left (b^2-4 a c\right ) \left (a+b x^n+c x^{2 n}\right )} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 364
Rule 1558
Rule 1560
Rubi steps
\begin {align*} \int \frac {(f x)^m \left (d+e x^n\right )}{\left (a+b x^n+c x^{2 n}\right )^2} \, dx &=\frac {(f x)^{1+m} \left (b^2 d-2 a c d-a b e+c (b d-2 a e) x^n\right )}{a \left (b^2-4 a c\right ) f n \left (a+b x^n+c x^{2 n}\right )}-\frac {\int \frac {(f x)^m \left (-a b e (1+m)-2 a c d (1+m-2 n)+b^2 d (1+m-n)+c (b d-2 a e) (1+m-n) x^n\right )}{a+b x^n+c x^{2 n}} \, dx}{a \left (b^2-4 a c\right ) n}\\ &=\frac {(f x)^{1+m} \left (b^2 d-2 a c d-a b e+c (b d-2 a e) x^n\right )}{a \left (b^2-4 a c\right ) f n \left (a+b x^n+c x^{2 n}\right )}-\frac {\int \left (\frac {\left (c (b d-2 a e) (1+m-n)+\frac {c \left (b^2 d-4 a c d+b^2 d m-4 a c d m-b^2 d n+8 a c d n-2 a b e n\right )}{\sqrt {b^2-4 a c}}\right ) (f x)^m}{b-\sqrt {b^2-4 a c}+2 c x^n}+\frac {\left (c (b d-2 a e) (1+m-n)-\frac {c \left (b^2 d-4 a c d+b^2 d m-4 a c d m-b^2 d n+8 a c d n-2 a b e n\right )}{\sqrt {b^2-4 a c}}\right ) (f x)^m}{b+\sqrt {b^2-4 a c}+2 c x^n}\right ) \, dx}{a \left (b^2-4 a c\right ) n}\\ &=\frac {(f x)^{1+m} \left (b^2 d-2 a c d-a b e+c (b d-2 a e) x^n\right )}{a \left (b^2-4 a c\right ) f n \left (a+b x^n+c x^{2 n}\right )}-\frac {\left (c \left ((b d-2 a e) (1+m-n)-\frac {4 a c d (1+m-2 n)-b^2 d (1+m-n)+2 a b e n}{\sqrt {b^2-4 a c}}\right )\right ) \int \frac {(f x)^m}{b-\sqrt {b^2-4 a c}+2 c x^n} \, dx}{a \left (b^2-4 a c\right ) n}-\frac {\left (c \left ((b d-2 a e) (1+m-n)+\frac {4 a c d (1+m-2 n)-b^2 d (1+m-n)+2 a b e n}{\sqrt {b^2-4 a c}}\right )\right ) \int \frac {(f x)^m}{b+\sqrt {b^2-4 a c}+2 c x^n} \, dx}{a \left (b^2-4 a c\right ) n}\\ &=\frac {(f x)^{1+m} \left (b^2 d-2 a c d-a b e+c (b d-2 a e) x^n\right )}{a \left (b^2-4 a c\right ) f n \left (a+b x^n+c x^{2 n}\right )}-\frac {c \left ((b d-2 a e) (1+m-n)-\frac {4 a c d (1+m-2 n)-b^2 d (1+m-n)+2 a b e n}{\sqrt {b^2-4 a c}}\right ) (f x)^{1+m} \, _2F_1\left (1,\frac {1+m}{n};\frac {1+m+n}{n};-\frac {2 c x^n}{b-\sqrt {b^2-4 a c}}\right )}{a \left (b^2-4 a c\right ) \left (b-\sqrt {b^2-4 a c}\right ) f (1+m) n}-\frac {c \left ((b d-2 a e) (1+m-n)+\frac {4 a c d (1+m-2 n)-b^2 d (1+m-n)+2 a b e n}{\sqrt {b^2-4 a c}}\right ) (f x)^{1+m} \, _2F_1\left (1,\frac {1+m}{n};\frac {1+m+n}{n};-\frac {2 c x^n}{b+\sqrt {b^2-4 a c}}\right )}{a \left (b^2-4 a c\right ) \left (b+\sqrt {b^2-4 a c}\right ) f (1+m) n}\\ \end {align*}
________________________________________________________________________________________
Mathematica [B] time = 6.52, size = 5363, normalized size = 14.34 \[ \text {Result too large to show} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [F] time = 0.60, size = 0, normalized size = 0.00 \[ {\rm integral}\left (\frac {{\left (e x^{n} + d\right )} \left (f x\right )^{m}}{c^{2} x^{4 \, n} + b^{2} x^{2 \, n} + 2 \, a b x^{n} + a^{2} + 2 \, {\left (b c x^{n} + a c\right )} x^{2 \, n}}, x\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {{\left (e x^{n} + d\right )} \left (f x\right )^{m}}{{\left (c x^{2 \, n} + b x^{n} + a\right )}^{2}}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [F] time = 0.04, size = 0, normalized size = 0.00 \[ \int \frac {\left (e \,x^{n}+d \right ) \left (f x \right )^{m}}{\left (b \,x^{n}+c \,x^{2 n}+a \right )^{2}}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F] time = 0.00, size = 0, normalized size = 0.00 \[ \frac {{\left (b^{2} d f^{m} - {\left (2 \, c d f^{m} + b e f^{m}\right )} a\right )} x x^{m} + {\left (b c d f^{m} - 2 \, a c e f^{m}\right )} x e^{\left (m \log \relax (x) + n \log \relax (x)\right )}}{a^{2} b^{2} n - 4 \, a^{3} c n + {\left (a b^{2} c n - 4 \, a^{2} c^{2} n\right )} x^{2 \, n} + {\left (a b^{3} n - 4 \, a^{2} b c n\right )} x^{n}} - \int \frac {{\left (b^{2} d f^{m} {\left (m - n + 1\right )} - {\left (2 \, c d f^{m} {\left (m - 2 \, n + 1\right )} + b e f^{m} {\left (m + 1\right )}\right )} a\right )} x^{m} + {\left (b c d f^{m} {\left (m - n + 1\right )} - 2 \, a c e f^{m} {\left (m - n + 1\right )}\right )} e^{\left (m \log \relax (x) + n \log \relax (x)\right )}}{a^{2} b^{2} n - 4 \, a^{3} c n + {\left (a b^{2} c n - 4 \, a^{2} c^{2} n\right )} x^{2 \, n} + {\left (a b^{3} n - 4 \, a^{2} b c n\right )} x^{n}}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [F] time = 0.00, size = -1, normalized size = -0.00 \[ \int \frac {{\left (f\,x\right )}^m\,\left (d+e\,x^n\right )}{{\left (a+b\,x^n+c\,x^{2\,n}\right )}^2} \,d x \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________